﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace CSW.Security
{
    /// <summary>
    /// Security_RoleAppFunction
    /// </summary>
    public partial class Security_RoleAppFunction
    {
        private Property<int> m_RoleID;
        private Property<int> m_AppFunctionID;
        private Property<int> m_RoleAppFunctionID;

        /// <summary>
        /// Called at the end of the constructor.
        /// </summary>
        protected override void base_OnCreated()
        {
            m_RoleAppFunctionID = new Property<int>(this, "RoleAppFunctionID");
            m_RoleID = new Property<int>(this, "RoleID");
            m_AppFunctionID = new Property<int>(this, "AppFunctionID");
            
            m_RoleAppFunctionID.IsReadOnly = true;

            AddRequiredField(m_RoleID, "Role is required.");
            AddRequiredField(m_AppFunctionID, "AppFunction is required.");
        }

        private void GeneratedOnRoleIDChanging(int value)
        {
            m_RoleID.CheckEdittable();
        }

        private void GeneratedOnAppFunctionIDChanging(int value)
        {
            m_AppFunctionID.CheckEdittable();
        }

        private void GeneratedOnRoleAppFunctionIDChanging(int value)
        {
            m_RoleAppFunctionID.CheckEdittable();
        }
    }
}
